From 02af4f3cd36bd4adf1f5d35852f08d1d74ede0da Mon Sep 17 00:00:00 2001 From: Alastair Tse Date: Thu, 5 Oct 2006 17:29:19 +0100 Subject: [PATCH] [XEND][XENAPI] XendCheckpoint should use XendConfig for passing configs. Signed-off-by: Alastair Tse --- tools/python/xen/xend/XendCheckpoint.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/tools/python/xen/xend/XendCheckpoint.py b/tools/python/xen/xend/XendCheckpoint.py index 158c6c3781..3b6baf5710 100644 --- a/tools/python/xen/xend/XendCheckpoint.py +++ b/tools/python/xen/xend/XendCheckpoint.py @@ -109,7 +109,7 @@ def save(fd, dominfo, network, live, dst): raise Exception, exn -def restore(xd, fd): +def restore(xd, fd, dominfo = None): signature = read_exact(fd, len(SIGNATURE), "not a valid guest state file: signature read") if signature != SIGNATURE: @@ -129,7 +129,11 @@ def restore(xd, fd): vmconfig = p.get_val() - dominfo = xd.restore_(vmconfig) + if dominfo: + dominfo.update(XendConfig(sxp = vmconfig), refresh = False) + dominfo.resume() + else: + dominfo = xd.restore_(vmconfig) store_port = dominfo.getStorePort() console_port = dominfo.getConsolePort() -- 2.30.2